package com.qs.core.dao; 

import java.io.Serializable;
import java.util.List;

import org.hibernate.Session;


public interface GenericDAO
{
    public  Serializable create(Object obj)throws Exception;
    public  Session getSession()throws Exception;
    public  Session getReadOnlySession()throws Exception;
    public  List select(Class type,String propList[])throws Exception;
    public  Object get(Class type,Serializable id)throws Exception;
    public  void update(Object obj)throws Exception;
    public  Object saveOrUpdate(Object o) throws Exception;
    public  void updateWithHistory(Object obj)throws Exception;
    public  void delete(Object obj)throws Exception;
    public  List selectByColumnAndValue(Class type,String aStrColumnName, Object aValueObj, String Orderby,String propList[])throws Exception;
    public  List selectByColumnAndValueWithIgnoreCase(Class type,String aStrColumnName, Object aValueObj, String Orderby,String propList[])throws Exception;
    public  List selectByColumnAndValue(Class type,String aStrColumnName[], Object aValueObj[], String orderBy[], String sortingOrder,String propList[])throws Exception;
    public  List selectForColumnByValues(Class type,String aStrColumnName, List Values,String propList[])throws Exception;
    public  Long countRow(Class type)throws Exception;
    public  Long countRow(Class type,String aStrColumnName[], Object aValueObj[])throws Exception;
    public  List selectRowsByIndexing(Class type,String aStrColumnName, Object aValueObj, String Orderby, int startIndex, int endIndex)throws Exception;
    public  Long genNextValOfSequence(String seq)throws Exception;

   
}